#ifndef ADVERTISING_H
#define ADVERTISING_H

#include <QProcess>
#include <QSettings>
#include <QFile>
#include <QCoreApplication>
#include <QMessageBox>
#include <QDebug>
#include "mainwindow.h"

#ifndef __cplusplus
extern "C"
{
#endif

//c程序的接口来自linux，所以，该qt程序只能在linux下进行编译
#include <stdlib.h>

#ifndef __cplusplus
}
#endif

class Advertising : public /*QProcess,*/ QObject
{
public:
    Advertising();
    void start();
    void kill();

private slots:
    void finished(int exitCode, QProcess::ExitStatus exitStatus);

private:
    MainWindow w;
    QSettings *settings;
    QString mplayerPath;
    QString playUrl;
    QProcess *process;
    QStringList cmdStringListParam;

};

#endif // ADVERTISING_H
